﻿using PlaceOrder_Core.PlaceOrderModels;
using PlaceOrder_Shared.Models.Common;
using PlaceOrder_Shared.Models.Enum;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace PlaceOrder_Core.Services.Interfaces
{
    public interface IUserHelper
    {
        bool LoginCandleMaintain(out string msg);
        bool AddUser(UserInfo ui, out string msg);
        bool UpdateUser(UserInfo ui, out string msg);
        public int AddUserTrade(UserTrade trade, string UserToken, out int UserTradeID, out string msg, out int ActualVolume, ref string ChangePriceTradeIDs,out int brokerId,out string orderMessage);
        bool ModifyUserTrade(UserTrade trade, string UserToken,out string msg,out string returnMsg);

        public bool CheckAdminRole(int userID);
        Task<(string, bool)> Login(UserInfo userInfo,int i=0);


        #region http相关
        public bool CancelUserTrade(long userTradeID, string UserToken, out string msg, out string returnMsg,int i=0);

        //平仓操作
        public int PingCangUserTrade(UserTrade trade, string UserToken, out string msg,out int brokerId);


        #endregion
    }
}
